Skip to main content

linux

GNU/Linux

History

  • Started in 1983 by Richard Stallman, the GNU Project aimed to build a free Unix-like OS
  • By the early 1990s, GNU lacked a kernel until Linus Torvalds created the Linux kernel in 1991, released under the GNU GPL in 1992
  • Together, they formed GNU/Linux, a free, open-source alternative to proprietary Unix
  • GNU/Linux is packaged into user-friendly distributions like Ubuntu, Debian, and Fedora, each offering unique features and interfaces

Key features

  • Free and open-source, unlike paid Unix systems
  • GNU tools paired with the Linux kernel
  • Kernel manages CPU, memory, and storage
  • Distributions (e.g., Ubuntu for beginners, Debian for stability, Fedora for cutting-edge updates) make GNU/Linux accessible

Learn more

Linux Directory Structure

img

Basic Commands

Fun fact: A directory is a just a file containing the names of other files

CategoryPopular Commands
File System Navigationcd, pwd, ls
File & Directory Mgmtcp, mv, rm, mkdir, touch, ln -s
Viewing & Editing Filescat, less, head, tail, nano, vim
Searching Files & Textfind, grep, locate, wc
Permissions & Ownershipchmod, chown, chgrp
Process Managementps, top, htop, kill, killall
System Informationuname, uptime, df -h, du -sh, free -h
Hardware Informationlscpu, lsblk, lspci, lsusb
Networkingping, ip/ifconfig, ssh, scp, wget, curl
Archiving & Compressiontar, gzip, gunzip, zip, unzip
Package Managementapt/dnf/yum/pacman (install, remove, update)
User & Group Managementsudo, su, useradd, usermod, passwd, whoami, id
Disk Managementlsblk, df -h, mount, umount, fdisk -l
System Services (systemd)systemctl (start, stop, status, enable, disable)
Job Schedulingcrontab -e, crontab -l, at
Shell Environmentecho, export, alias, source, env
Command History & Helphistory, man, --help, apropos
System Controlshutdown, reboot, clear, hostname
Development Toolsgit, make, gcc/g++
Miscellaneous Utilitieswatch, tee, sleep, which, type, xargs

Practice

#
ssh

#
telnet google 80

#
man telnet

#
telnet --help

#
which telnet

#
ls /usr/bin | grep telnet

#
docker ps -a | awk 'NR>2 {print $2}'

Shell, Console, and Terminal - Continue - 1:19:13

Console

  • Physical devices to interact with the computer such as screen, keyboard, and mouse

Terminal

  • A program acts as a wrapper to enter commands

Shell

  • A command line interpreter that receives and executes commands